define(function (require) {
    var a = require("jqueryui"), b = (require("underscore"), require("crossflow")), c = b.klass({
        tpl: function () {
            var a = '<div class="license-info-inner"> <div class="content"></div> <span class="btn-glyphicon close-msg">     <span class="glyphicon glyphicon-close"></span> </span></div>';
            return a
        }(), __init__: function (a, b) {
            this.$elem = a, this.opts = b, this._render()
        }, _render: function () {
            var b = this;
            this.$elem.empty().append(a(this.tpl)), this.$elem.hide(), this.$elem.find(".close-msg").bind("click", function () {
                b._hide()
            }), this.$elem.find(".content").bind("click", function () {
                b._showAbout()
            })
        }, fetch: function () {
            var b = this;
            a.ajax({
                url: b.opts.checkUrl, type: "GET", dataType: "json", success: function (a) {
                    a.ok && b._show(a.result)
                }, error: function (a) {
                }
            })
        }, _hide: function () {
            this.$elem.slideUp()
        }, _show: function (a) {
            a.valid || (this.$elem.find(".content").text(a.errors), this.$elem.css({"margin-left": -this.$elem.width() / 2}), this.$elem.slideDown())
        }, _showAbout: function () {
            var a = 287, b = 550;
            height = window.screen.height, width = window.screen.width, y = height / 2 - a / 2, x = width / 2 - b / 2, attr = "top=" + y + ",", attr += "left=" + x + ",", attr += "status=no,menubar=no,scrollbars=no,resizable=no,", attr += "width=" + b + ",", attr += "height=" + a, window.open(this.opts.aboutUrl, "_blank", attr)
        }
    });
    return c
});
/**
 * Created by 77element-01 on 2016/4/12.
 */
